package org.example.Dao;

import org.apache.ibatis.annotations.Lang;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.example.Entity.Score;
import org.example.Entity.Student;

import java.util.List;

@Mapper
public interface GradeDao  {
    //插入学生
    int insertStudent(Student student);
    //查询学生
    List<Student> selectStudentById(Student student);
    //查询学生
    List<Student> selectStudentById2(Student student);
    //插入成绩
    int insertGrade(Score score);
    //学生端分页查询
    List<Student> selectStudentGrade(Score score);
    //查询成绩
    List<Student> selectOneGrade(String studentId);
    //查询单条成绩
    List<Student> selectTwoGrade(@Param("studentId") String studentId,@Param("courseId") int courseId);
    List<Student> selectAllGrade();
    List<Student> selectAllGrade1(Score score);
    //删除学生
    int deleteStudent(String studentId);
    //删除成绩
    int deleteGrade(@Param("courseId") int courseId, @Param("studentId") String studentId);
    //修改成绩
    int updateStudentGrade(Score score);
}
